﻿using System;
using System.Collections.Generic;
using System.Data.Entity.ModelConfiguration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Himall.Entity.Config
{
   public class BrowsingHistoryInfoConfig : EntityTypeConfiguration<BrowsingHistoryInfo>
    {
        public BrowsingHistoryInfoConfig()
        {
            ToTable("Himall_BrowsingHistory");      
            HasRequired(x => x.Himall_Members).WithMany(x => x.Himall_BrowsingHistory).HasForeignKey(x => x.MemberId);
            HasRequired(x => x.Himall_Products).WithMany(x => x.Himall_BrowsingHistory).HasForeignKey(x => x.ProductId);
        }
    }
}
